package timing.ukulele.common;

import java.util.concurrent.TimeUnit;

public interface Constant {

    String TOKEN = "X-TOKEN";
    String BIZ_TOKEN = "X-SECRET";
    String APP = "X-APP";

    String USER_INFO = "USER-INFO";
    int EXPIRE_HOURS = 12;

    long EXPIRE_MILLIS = TimeUnit.HOURS.toMillis(EXPIRE_HOURS);

    int EXPIRE_MINUTES = Math.toIntExact(EXPIRE_MILLIS / 1000);

    // 业务系统请求的头部用户信息
    String BUSINESS_USERNAME = "B-USERNAME";
    String BUSINESS_NAME = "B-NAME";

    // 系统自身请求的头部用户信息
    String USERNAME = "X-USERNAME";
    String NAME = "X-NAME";
    String SYSTEM = "X-SYSTEM";
    String ROLE = "X-ROLE";
}
